﻿<Application
    x:Class="UtilityApp.App"
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:phone="clr-namespace:Microsoft.Phone.Controls;assembly=Microsoft.Phone"
    xmlns:shell="clr-namespace:Microsoft.Phone.Shell;assembly=Microsoft.Phone">

    <!--Application Resources-->
    <Application.Resources>
        <local:LocalizedStrings xmlns:local="clr-namespace:UtilityApp" x:Key="LocalizedStrings"/>
        <SolidColorBrush x:Key="MyYellow01" Color="#7F53B027"/>
        <LinearGradientBrush x:Key="RainbowColor" EndPoint="0.5,1" StartPoint="0.5,0">
            <GradientStop Color="#FF9500EA" Offset="0.042"/>
            <GradientStop Color="Red" Offset="1"/>
            <GradientStop Color="#FF4961FF" Offset="0.182"/>
            <GradientStop Color="#FF0022F9" Offset="0.325"/>
            <GradientStop Color="#FF006E0F" Offset="0.503"/>
            <GradientStop Color="#FFDCFF00" Offset="0.692"/>
            <GradientStop Color="#FFFFA200" Offset="0.846"/>
        </LinearGradientBrush>
        <ImageBrush x:Key="WowZappBrush" ImageSource="/Images/WOWZAPP2012_200x200.jpg"/>
        <DataTemplate x:Key="TwitterPostTemplate">
            <Grid Width="450" Height="150" 
                  Background="Green">
                <Grid.ColumnDefinitions>
                    <ColumnDefinition Width="150"/>
                    <ColumnDefinition Width="*"/>
                </Grid.ColumnDefinitions>
                <Image Grid.Column="0"
                       Source="{Binding ImagePath}"/>
                <StackPanel Background="Yellow" 
                            Grid.Column="1">
                    <TextBlock Text="{Binding UserName}"/>
                    <TextBlock Text="{Binding Text}"/>
                </StackPanel>
            </Grid>
        </DataTemplate>
    </Application.Resources>

    <Application.ApplicationLifetimeObjects>
        <!--Required object that handles lifetime events for the application-->
        <shell:PhoneApplicationService
            Launching="Application_Launching" Closing="Application_Closing"
            Activated="Application_Activated" Deactivated="Application_Deactivated"/>
    </Application.ApplicationLifetimeObjects>

</Application>